//
//  RoomModel.h
//  buka
//
//  Created by 曹飞 on 16/7/13.
//  Copyright © 2016年 songhuipan. All rights reserved.
//

#import <Foundation/Foundation.h>

typedef NS_ENUM(NSInteger,RoomClientType) {
    RoomClientTypeWeb,
    RoomClientTypePC,
    RoomClientTypeMobile,
    RoomClientTypeUnknow
};


//房间开课状态
typedef  NS_ENUM(NSInteger,RoomStatus) {
    RoomStatusBeginning, //已开始
    RoomStatusNotBegin, //未开始
    RoomStatusFinished, //已结束
    RoomStatusLong,  //长期课
    RoomStatusIsSeries //系列课
};


//在课程的扩展字段里面有一个top_url和buttom_url   top_url的是那个22px的图
@interface BKCourseChapterExtend : NSObject

@property (nonatomic,strong)NSString * startClass;
@property (nonatomic,strong)NSString * startImg;
@property (nonatomic,strong)NSString * top_url;
@property (nonatomic,strong)NSString * buttom_url;

@end





@interface BKRoomModel : NSObject<NSCoding>

@property (nonatomic,assign) BOOL isList; //是否是课节列表 默认是NO，不是

@property (nonatomic,strong) BKCourseChapterExtend * course_chapter_extend;

@property (nonatomic,strong) NSString * user_nickname;
@property (nonatomic,strong) NSString * room_type;//3直播 2 是竖屏
@property (nonatomic,strong) NSString * room_encryption; //如果是1，那就是有密码的房间

@property (nonatomic,strong) NSString * user_identity;
@property (nonatomic,strong) NSString * room_sdk_id; //播放端使用的sdkID
@property (nonatomic,strong) NSString * room_alias;
@property (nonatomic,strong) NSString * room_create_time;
@property (nonatomic,strong) NSString * room_description;
@property (nonatomic,strong) NSString * user_room_max_user_num;
@property (nonatomic,strong) NSString * phone_num;
@property (nonatomic,strong) NSString * room_id;
@property (nonatomic,strong) NSString * user_id;
@property (nonatomic,strong) NSString * user_birthday;
@property (nonatomic,strong) NSString * user_sex;
@property (nonatomic,strong) NSString * room_name;
@property (nonatomic,strong) NSString * role; //用户角色 1 主讲人2 普通学生：进入课堂需要接口进行校验3 助教4 隐形人5 白名单内的学生：进入课堂不需要接口校验（信令里和归到2里面）6 课程创建者
@property (nonatomic,strong) NSString * user_area;
@property (nonatomic,strong) NSString * user_avatar_url;
@property (nonatomic,strong) NSString * teacher_nickame; //
@property (nonatomic,strong) NSString * room_img_url;
@property (nonatomic,strong) NSString * room_like_num;
@property (nonatomic,strong) NSString * room_password;
@property (nonatomic,strong) NSArray * room_role_encryption;
@property (nonatomic,assign) BOOL isSelect; //列表多选用
@property (nonatomic,assign) NSInteger auto_record;



//新接口
@property (nonatomic,strong) NSString * course_create_user_num;
@property (nonatomic,strong) NSString * speaker_user_name;
@property (nonatomic,strong) NSString * speaker_user_num;
@property (nonatomic,strong) NSString * assistant_user_num;
@property (nonatomic,strong) NSArray * assistant_users;
@property (nonatomic,strong) NSString * pwd;
@property (nonatomic,strong) NSString * course_chapter_pwd;

@property (nonatomic,strong) NSString * content;
@property (nonatomic,strong) NSString * course_content;
@property (nonatomic,assign) int now_price;
@property (nonatomic,assign) long course_id;

@property (nonatomic,strong) NSString * course_title;
@property (nonatomic,strong) NSString * course_chapter_title; //课程title


@property (nonatomic,strong) NSString * course_code; //生成订单的时候需要传递
@property (nonatomic,strong) NSString * course_thumb_url;
@property (nonatomic,assign) int course_original_price;
@property (nonatomic,assign) int course_now_price;
@property (nonatomic,assign) int course_share_prime_price;
@property (nonatomic,strong) NSString * course_type_name;
@property (nonatomic,assign) long course_create_user_id; //创建者id（可以忽略）
@property (nonatomic,assign) long course_create_time;//创建时间
@property (nonatomic,assign) long course_share_time;
@property (nonatomic,assign) int course_is_shared;
@property (nonatomic,assign) int course_is_series;
@property (nonatomic,assign) int course_like_num;
@property (nonatomic,assign) int course_chapter_num;
@property (nonatomic,assign) long course_chapter_id;  //房间id
@property (nonatomic,assign) BOOL course_is_finished;
@property (nonatomic,assign) int course_chapter_index;
@property (nonatomic,assign) long course_chapter_start_time;//开始时间
@property (nonatomic,assign) long course_chapter_end_time;//结束时间
@property (nonatomic,assign) long course_money_rate_id;
@property (nonatomic,assign) long course_join_end_time;
@property (nonatomic,assign) long course_encryption; //废弃



@property (nonatomic,strong) NSString * series_course_title;
@property (nonatomic,strong) NSString * course_introduce;
@property (nonatomic,strong) NSString * course_extend;

@property (nonatomic,assign) int encryption;
@property (nonatomic,assign) int course_chapter_encryption;
@property (nonatomic,strong) NSString * course_chapter_speaker_user_name; //搜索出来的主讲名称
@property (nonatomic,strong) NSString * course_chapter_speaker_user_id; 
@property (nonatomic,strong) NSString * course_chapter_type;     //房间类型 1互动，2微信直播

@property (nonatomic,strong) NSString * course_chapter_alias;    //房间别名
@property (nonatomic,strong) NSString * auto_upstage;            //是否自动上台 1 不自动上台，2自动
@property (nonatomic,assign) int ordered; //0未报名，1已经报名

@property (nonatomic,strong) NSString * course_local_code;//创建临时会议的房间code
//判断房间是什么端发布的
-(RoomClientType)whereClient:(BKRoomModel*)model;

//返回课程是否已开课还是已结束
-(RoomStatus)courseStatus;

@end


